feat: [cel] add CEL-based assertions and offline VAP evaluation#562
feat: [cel] add CEL-based assertions and offline VAP evaluation#562crandles wants to merge 2 commits into
Conversation
|
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: crandles The full list of commands accepted by this bot can be found here. DetailsNeeds approval from an approver in each of these files:Approvers can indicate their approval by writing |
|
Hi @crandles. Thanks for your PR. I'm waiting for a kubernetes-sigs member to verify that this patch is reasonable to test. If it is, they should reply with Tip We noticed you've done this a few times! Consider joining the org to skip this step and gain Once the patch is verified, the new status will be reflected by the I understand the commands that are listed here. DetailsInstructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository. |
|
Unknown CLA label state. Rechecking for CLA labels. Send feedback to sig-contributor-experience at kubernetes/community. /check-cla |
|
/ok-to-test |
|
Thanks! I'll dig into the failures |
vladimirvivien
left a comment
There was a problem hiding this comment.
hi @crandles - this is an awesome submission (as were all of your contributions). Because of its size, it will take me some time to digest everything.
Quick feed back: consider making cel a top root package instead of klient/cel.
|
Happy to move it, naming is hard. Open to scoping down, or splitting over multiple PRs. It seemed like CEL would be nice throughout the project. On another note: Should I consider joining the org? |
|
golangci-lint version mismatch, seems I'm ahead and getting different results locally. |
|
I will be proposing this here, shortly, but in the meantime: I've added a Github Workflow that runs on forked-repository pull requests. It would be nice to catch simple errors sooner. Work in progress: crandles#1 |
Signed-off-by: Chris Randles <randles.chris@gmail.com>
|
@crandles yes, you should definitely consider joining the project as you've landed some great contributions in the past. We had golangci-lint version issues a few weeks back and were forced to update, so you may have to update your env. |
|
@crandles Let's split the PR into functional packages as you suggested. |
|
splitting per #562 (comment) -- #569 has the cel + cel/policy core (with an offline example). a follow-up PR will layer on cel/decoder, cel/feature, cel/wait + the live-cluster example. closing this in favor of the split. |
What type of PR is this?
/kind feature
What this PR does / why we need it:
Adds a
celpackage for writing CEL-based assertions against Kubernetes objects in tests. Same expression language the API server uses for CRD validation and admission policies, so tests don't drift from the policies they exercise.Design doc: docs/cel-assertions.md.
Which issue(s) this PR fixes:
Fixes #
Special notes for your reviewer:
Happy to split by sub-package if that's easier to review --
cel,policy,feature,wait,decodereach stand alone.Does this PR introduce a user-facing change?